<!DOCTYPE html>
<head>
  <title>pc_base</title>
  <meta charset="utf-8">

  <link type="text/css" rel="stylesheet" href="../highlight/styles/common.css">
  <link rel="alternate stylesheet" title="Zenburn" href="../highlight/styles/zenburn.css">
  <link rel="alternate stylesheet" title="Pojoaque" href="../highlight/styles/pojoaque.css">
  <link rel="alternate stylesheet" title="MonoBlue" href="../highlight/styles/mono-blue.css">
  <script src="../highlight/styleswitcher.js" type="text/javascript"></script>

  <link type="text/css" rel="stylesheet" href="../showpage/css/Dialog.1.0.css">
  <script src="../showpage/js/jquery-1.7.2.min.js" type="text/javascript"></script>
  <script type="text/javascript" src="../showpage/js/Dialog.js"></script>
  <script type="text/javascript">
	$(document).ready(function(){
		$(".load_sys_func").click(function(){
			var def_load_sys_func = {
				title:$(this).html(),
			}
			$.Dialog(def_load_sys_func);
			$.Dialog("load_sys_func.html",{type:"iframe",width: 620,height: 250});
		});
	});
  </script>
  
<style type="text/css">
a {
    color: red;
    text-decoration: none;
}
a:hover{
	color: blue;
	text-decoration:underline;
}
</style>
<body>

<div id="styleswitcher"></div>

<table id="autotest">
  <tr>
    <td class="php">
<pre><code>
define('IN_PHPCMS', true);

//PHPCMS框架路径
define('PC_PATH', dirname(__FILE__).DIRECTORY_SEPARATOR);

if(!defined('PHPCMS_PATH')) define('PHPCMS_PATH', PC_PATH.'..'.DIRECTORY_SEPARATOR);

//缓存文件夹地址
define('CACHE_PATH', PHPCMS_PATH.'caches'.DIRECTORY_SEPARATOR);
//主机协议
define('SITE_PROTOCOL', isset($_SERVER['SERVER_PORT']) && $_SERVER['SERVER_PORT'] == '443' ? 'https://' : 'http://');
//当前访问的主机名
define('SITE_URL', (isset($_SERVER['HTTP_HOST']) ? $_SERVER['HTTP_HOST'] : ''));
//来源
define('HTTP_REFERER', isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : '');

//系统开始时间
define('SYS_START_TIME', microtime());

//加载公用函数库
<a class="load_sys_func">pc_base::load_sys_func('global');</a>
<a class="load_sys_func">pc_base::load_sys_func('extention');</a>
pc_base::auto_load_func();

pc_base::load_config('system','errorlog') ? set_error_handler('my_error_handler') : error_reporting(E_ERROR | E_WARNING | E_PARSE);
//设置本地时差
function_exists('date_default_timezone_set') && date_default_timezone_set(pc_base::load_config('system','timezone'));

define('CHARSET' ,pc_base::load_config('system','charset'));
//输出页面字符集
header('Content-type: text/html; charset='.CHARSET);

define('SYS_TIME', time());
//定义网站根路径
define('WEB_PATH',pc_base::load_config('system','web_path'));
//js 路径
define('JS_PATH',pc_base::load_config('system','js_path'));
//css 路径
define('CSS_PATH',pc_base::load_config('system','css_path'));
//img 路径
define('IMG_PATH',pc_base::load_config('system','img_path'));
//动态程序路径
define('APP_PATH',pc_base::load_config('system','app_path'));

//应用静态文件路径
define('PLUGIN_STATICS_PATH',WEB_PATH.'statics/plugin/');

if(pc_base::load_config('system','gzip') && function_exists('ob_gzhandler')) {
	ob_start('ob_gzhandler');
} else {
	ob_start();
}
</code></pre>
    </td>
  </tr>
</table>
